<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head th:include="base/include/markdown">
</head>
<body>
<table>
	<tr>
		<td width="10%">标题：</td><td width="90%"><input class="easyui-textbox" width="200px;"/></td>
	</tr>
	<tr>
		<td>子标题：</td><td><input class="easyui-textbox"  width="200px;"/></td>
	</tr>
	<tr>
		<td>文章类型：</td><td><input class="easyui-textbox"  width="200px;"/></td>
	</tr>
	<tr>
		<td>文章：</td><td></td>
	</tr>
	<tr>
		<td colspan="2">
			<textarea id="demo1" rows="10" cols="20"></textarea>
		</td>
	</tr>
	<tr>
		<td colspan="2" style="text-align: center;">
			<a href="javascript:saveOrUpdateSunMasterCode('../masterCode/saveOrUpdateSunMasterCode')" class="easyui-linkbutton" iconCls="icon-add" >确定</a>
			<a href="javascript:parent.$('#win').window('close');" class="easyui-linkbutton" iconCls="icon-cancel">关闭</a>
		</td>
	</tr>
</table>
</body>
<script type="text/javascript">
$(function(){
});
var simplemde = new SimpleMDE({
	element: document.getElementById("demo1"),
	spellChecker: false,
	status : false
});

function castHtml(){
	var testPlain = simplemde.value();
    var testMarkdown = simplemde.markdown(testPlain);
	alert(testPlain);
	alert(testMarkdown);
}
</script>
</html>